<form action="{:url()}" method="post" data-auto="true" class="layui-form layui-card" data-table-id="CategoryTable">

    <div class="layui-card-body">
        <div class="layui-form-item">
            <label class="layui-form-label">币种代码</label>
            <div class="layui-input-block">
                <input name="code" value="{$vo.code|default=''}" required vali-name="币种代码" placeholder="请输入币种代码" class="layui-input" type="text">
                <p class="help-block"><b>必选</b>，请填写币种代码</p>
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">是否放在首页</label>
            <div class="layui-input-block">
                <input type="radio" name="is_primary" value="1" title="是" {if $vo.is_primary==1 }checked{/if}> <!-- 默认选中“开启” -->
                <input type="radio" name="is_primary" value="0" title="否" {if $vo.is_primary==0 }checked{/if}>
                <p class="help-block"><b>必选</b>，不放在首页就放在列表页</p>
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">币种icon</label>
            <div class="layui-input-block">
                <input type="hidden" data-accept-mime="image/*" data-cut-width="96" data-cut-height="96"  required data-max-width="96" data-max-height="96" data-file-type="1" name="icon" value="{$vo.icon|default=''}">
                <script>$('[name=icon]').uploadOneImage();</script>
                <p class="help-block"><b>必选</b>，请上传火币对应币种icon</p>
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">排序</label>
            <div class="layui-input-block">
                <input type="number" name="sort" required vali-name="排序" placeholder="请输入排序" value="{$vo.sort|default='50'}" class="layui-input">
                <p class="help-block">
                    <b>必须是数字排序越小越靠前</b>
                </p>
            </div>
        </div>
    </div>
    <div class="hr-line-dashed"></div>
    {notempty name='vo.id'}<input type='hidden' value='{$vo.id}' name='id'>
    {/notempty}
    <div class="layui-form-item text-center">
        <button class="layui-btn" type='submit'>保存数据</button>
        <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定要取消编辑吗？" data-close>取消编辑</button>
    </div>
</form>
